package com.test.ioc.bean;

import org.springframework.stereotype.Component;

/**
 * @author SN
 * @date 2020/4/17 11:38
 * @desc
 */
@Component
public class Person {

    private String name;
    private Integer age;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    @Override
    public String toString() {
        return "Person{" +
                "name='" + name + '\'' +
                ", age=" + age +
                '}';
    }

    //    public void initPerson(){
//        System.out.println("Person创建");
//    }
//
//    public void destroyPerson(){
//        System.out.println("Person销毁");
//    }

}